Optimal. Leaf size=180 \[ -\frac {(3-n) (8-n) (16-n) (a \sec (c+d x)+a)^{n+4} \, _2F_1(6,n+4;n+5;\sec (c+d x)+1)}{42 a^4 d (1-n) (n+4)}+\frac {\cos ^7(c+d x) \left (6 (8-n)-\left (n^2-25 n+108\right ) \sec (c+d x)\right ) (a \sec (c+d x)+a)^{n+4}}{42 a^4 d (1-n)}-\frac {\cos ^7(c+d x) (1-\sec (c+d x))^2 (a \sec (c+d x)+a)^{n+4}}{a^4 d (1-n)} \]
[Out]
________________________________________________________________________________________
Rubi [A] time = 0.17, antiderivative size = 180, normalized size of antiderivative = 1.00, number of steps used = 4, number of rules used = 4, integrand size = 21, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.190, Rules used = {3873, 100, 145, 65} \[ -\frac {(3-n) (8-n) (16-n) (a \sec (c+d x)+a)^{n+4} \, _2F_1(6,n+4;n+5;\sec (c+d x)+1)}{42 a^4 d (1-n) (n+4)}+\frac {\cos ^7(c+d x) \left (6 (8-n)-\left (n^2-25 n+108\right ) \sec (c+d x)\right ) (a \sec (c+d x)+a)^{n+4}}{42 a^4 d (1-n)}-\frac {\cos ^7(c+d x) (1-\sec (c+d x))^2 (a \sec (c+d x)+a)^{n+4}}{a^4 d (1-n)} \]
Antiderivative was successfully verified.
[In]
[Out]
Rule 65
Rule 100
Rule 145
Rule 3873
Rubi steps
\begin {align*} \int (a+a \sec (c+d x))^n \sin ^7(c+d x) \, dx &=-\frac {\operatorname {Subst}\left (\int \frac {(-a-a x)^3 (a-a x)^{3+n}}{x^8} \, dx,x,-\sec (c+d x)\right )}{a^6 d}\\ &=-\frac {\cos ^7(c+d x) (1-\sec (c+d x))^2 (a+a \sec (c+d x))^{4+n}}{a^4 d (1-n)}-\frac {\operatorname {Subst}\left (\int \frac {(-a-a x) (a-a x)^{3+n} \left (a^3 (8-n)+a^3 (4-n) x\right )}{x^8} \, dx,x,-\sec (c+d x)\right )}{a^7 d (1-n)}\\ &=-\frac {\cos ^7(c+d x) (1-\sec (c+d x))^2 (a+a \sec (c+d x))^{4+n}}{a^4 d (1-n)}+\frac {\cos ^7(c+d x) (a+a \sec (c+d x))^{4+n} \left (6 (8-n)-\left (108-25 n+n^2\right ) \sec (c+d x)\right )}{42 a^4 d (1-n)}+\frac {((3-n) (8-n) (16-n)) \operatorname {Subst}\left (\int \frac {(a-a x)^{3+n}}{x^6} \, dx,x,-\sec (c+d x)\right )}{42 a^3 d (1-n)}\\ &=-\frac {(3-n) (8-n) (16-n) \, _2F_1(6,4+n;5+n;1+\sec (c+d x)) (a+a \sec (c+d x))^{4+n}}{42 a^4 d (1-n) (4+n)}-\frac {\cos ^7(c+d x) (1-\sec (c+d x))^2 (a+a \sec (c+d x))^{4+n}}{a^4 d (1-n)}+\frac {\cos ^7(c+d x) (a+a \sec (c+d x))^{4+n} \left (6 (8-n)-\left (108-25 n+n^2\right ) \sec (c+d x)\right )}{42 a^4 d (1-n)}\\ \end {align*}
________________________________________________________________________________________
Mathematica [A] time = 1.51, size = 113, normalized size = 0.63 \[ \frac {(\sec (c+d x)+1)^4 (a (\sec (c+d x)+1))^n \left ((n+4) \cos ^5(c+d x) \left (\left (n^2-25 n+24\right ) \cos (c+d x)+6 (n-1) \cos ^2(c+d x)+42\right )-\left (n^3-27 n^2+200 n-384\right ) \, _2F_1(6,n+4;n+5;\sec (c+d x)+1)\right )}{42 d (n-1) (n+4)} \]
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
fricas [F] time = 0.63, size = 0, normalized size = 0.00 \[ {\rm integral}\left (-{\left (\cos \left (d x + c\right )^{6} - 3 \, \cos \left (d x + c\right )^{4} + 3 \, \cos \left (d x + c\right )^{2} - 1\right )} {\left (a \sec \left (d x + c\right ) + a\right )}^{n} \sin \left (d x + c\right ), x\right ) \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
giac [F] time = 0.00, size = 0, normalized size = 0.00 \[ \int {\left (a \sec \left (d x + c\right ) + a\right )}^{n} \sin \left (d x + c\right )^{7}\,{d x} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
maple [F] time = 3.01, size = 0, normalized size = 0.00 \[ \int \left (a +a \sec \left (d x +c \right )\right )^{n} \left (\sin ^{7}\left (d x +c \right )\right )\, dx \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
maxima [F] time = 0.00, size = 0, normalized size = 0.00 \[ \int {\left (a \sec \left (d x + c\right ) + a\right )}^{n} \sin \left (d x + c\right )^{7}\,{d x} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
mupad [F] time = 0.00, size = -1, normalized size = -0.01 \[ \int {\sin \left (c+d\,x\right )}^7\,{\left (a+\frac {a}{\cos \left (c+d\,x\right )}\right )}^n \,d x \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
sympy [F(-1)] time = 0.00, size = 0, normalized size = 0.00 \[ \text {Timed out} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________